<template>
  <div class="news-wrapper">
    <slot></slot>
  </div>
</template>
<script>
  const Item = {
    name: 'newsListItem',
    props: {
      content: {
        type: String,
        default: '',
        required: false,
      },
      date: {
        type: String,
        default: '',
        required: false,
      },
    },
    render() {
      return (
        <div class="news-item-wrapper">
          <span class="news-item-tag">●</span>
          <div class="news-item-content">
            <a href="#">{this.$props.content}</a>
          </div>
          <div class="news-item-date">{this.$props.date}</div>
        </div>
      )
    },
  }
  export default {
    name: 'newsList',
    Item: Item,
    data() {
      return {
        advanced: false,
        toplist: [],
        bottomList: [],
      }
    },
  }
</script>
<style scoped lang="less">
  /deep/ .news-item-wrapper {
    height: 40px;
    font-size: 14px;
    line-height: 30px;
    border-bottom: 1px solid #e9e9e9;
    border-bottom: 1px solid #e9e9e9;
    .news-item-tag {
      font-size: 22px;
      color: #1890ff;
      display: inline-block;
    }
    .news-item-content {
      display: inline-block;
      margin-left: 13px;
      font-weight: 700;
    }
    .news-item-date {
      display: inline-block;
      float: right;
    }
  }
</style>
